<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width, initial-scale=1.0">
		<title></title>	
		<link rel="stylesheet" href="__STATIC__/assets/css/core.css" />
		<link rel="stylesheet" href="__STATIC__/assets/menu.css" />
		<link rel="stylesheet" href="__STATIC__/assets/css/amazeui.css"/>
		<link rel="stylesheet" href="__STATIC__/assets/component.css" />
		<link rel="stylesheet" href="__STATIC__/assets/css/page/form.css" />

        <script src="__STATIC__/assets/js/echarts.min.js"></script>

		<script type="text/javascript">
    function checkuser(){
        //获取输入的用户名
        var u=document.getElementById("inputEmail").value;
        //去数据库验证
        $.get("{:url('check')}",{"user":u},
            function(result){
        if (result==1)
        $("#tip").html("√").css("color","green");
        else $("#tip").html("×").css("color","red");
        });

        //处理服务端的返回值，显示结果
    }
</script>
	</head>

	

	<body>
		<div class="account-pages">
			<div class="wrapper-page">
				<div class="text-center">
	                <a href="index.html" class="logo"><span>ClubAdmin</span></a>
	            </div>
	            
	            <div class="m-t-40 card-box">
	            	<div class="text-center">
	                    <h4 class="text-uppercase font-bold m-b-0">登录</h4>
	                </div>
	                <div class="panel-body">
	                	
	                		<form class="am-form" action="{:url('index')}" method="post">
                            <div class="control-group">
                                <div class="controls">
                                    <input class="btn-block" type="text" name="adminname" id="inputEmail" placeholder="账号" onblur="checkuser()">
                                    <span id="tip"></span>
                                </div>
                            </div>
                            <div class="control-group">
                                <div class="controls">
                                    <input class="btn-block" type="password" id="inputPassword" placeholder="密码" name="password">
                                </div>
                            </div>
                            <div>
                        <input class="btn-block" type="text" id="verifycode" placeholder="验证码" name="verifycode">  
                            </div>
                        <div><img src="{:url('show_captcha')}" alt="captcha" 
                            onclick="this.src=this.src+'?'" /></div>

                             <div class="control-group">
                                <div class="controls clearfix">
                                    <label style="width:auto" class="checkbox pull-left">
                                        <input type="checkbox"> Remember me
                                    </label>
                                </div>
                            </div>                  
                            <button type="submit" class="btn pull-right">登录</button>
		                        </form>
	                		</div>

	                </div>
	            </div>
			</div>
	</body>
</html>
